class CalendarEventModel {
  int? errcode;
  String? errmsg;
  List<Data>? data;
  String? message;

  CalendarEventModel({this.errcode, this.errmsg, this.data, this.message});

  CalendarEventModel.fromJson(Map<String, dynamic> json) {
    errcode = json['errcode'];
    errmsg = json['errmsg'];
    if (json['data'] != null) {
      data = <Data>[];
      json['data'].forEach((v) {
        data!.add(new Data.fromJson(v));
      });
    }
    message = json['message'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['errcode'] = this.errcode;
    data['errmsg'] = this.errmsg;
    if (this.data != null) {
      data['data'] = this.data!.map((v) => v.toJson()).toList();
    }
    data['message'] = this.message;
    return data;
  }
}

class Data {
  String? date;
  int? num;

  Data({this.date, this.num});

  Data.fromJson(Map<String, dynamic> json) {
    date = json['date'];
    num = json['num'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['date'] = this.date;
    data['num'] = this.num;
    return data;
  }
}
